<template>
    <div
      :class="prefixCls"
      class="relative h-[100%] lt-md:px-10px lt-sm:px-10px lt-xl:px-10px lt-xl:px-10px"
    >
      <div class="relative mx-auto h-full flex">
        <div class="relative flex-1 p-30px dark:bg-[var(--login-bg-color)] lt-sm:p-10px">
          <!-- 右边的登录界面 -->
          <Transition appear enter-active-class="animate__animated animate__bounceInRight">
            <div
              class="m-auto h-full w-[100%] flex items-center at-2xl:max-w-500px at-lg:max-w-500px at-md:max-w-500px at-xl:max-w-500px"
            >
              <!-- 账号登录 -->
              <LoginForm class="m-auto h-auto p-20px lt-xl:(rounded-3xl light:bg-white)" />
            </div>
          </Transition>
        </div>
      </div>
    </div>
  </template>

<script lang="ts" setup>
import { useDesign } from '@/hooks/web/useDesign'

import LoginForm from './LoginForm.vue'

defineOptions({ name: 'Login' })

const { getPrefixCls } = useDesign()
const prefixCls = getPrefixCls('login')
</script>

<style lang="scss" scoped>
$prefix-cls: #{$namespace}-login;

.#{$prefix-cls} {
  overflow: auto;

  &__left {
    &::before {
      position: absolute;
      top: 0;
      left: 0;
      z-index: -1;
      width: 100%;
      height: 100%;
      background-image: url('@/assets/svgs/login-bg.svg');
      background-position: center;
      background-repeat: no-repeat;
      content: '';
    }
  }
}
</style>
